package ch.fusun.baron.city.ui;

import ch.fusun.baron.city.City;
import ch.fusun.baron.map.ui.gef.editpart.TileChild;
import ch.fusun.baron.swt.isometry.components.Sprite;

/**
 * Tile child for cities
 */
public class CityTileChild implements TileChild<City> {

	private static final String ICONS_CITY_MASK = "icons/city_mask.png"; //$NON-NLS-1$
	private static final String ICONS_CITY = "icons/city.png"; //$NON-NLS-1$
	private final City city;

	/**
	 * @param city
	 *            The city
	 */
	public CityTileChild(City city) {
		this.city = city;
	}

	@Override
	public City getModel() {
		return this.city;
	}

	@Override
	public Sprite getSprite() {
		return new Sprite(Activator.getImage(ICONS_CITY),
				Activator.getImage(ICONS_CITY_MASK), 20);
	}
}
